import 'dart:convert';

import 'package:crypto/crypto.dart';

class SignService {
  static String sign(Map param) {
    List keys = param.keys.toList();
    // 参数排序
    keys.sort();
    String tempString = "";
    for (var key in keys) {
      tempString += "$key${param[key]}";
    }
    var sign = md5.convert(utf8.encode(tempString));
    return sign.toString();
  }
}
